#数组广播
import numpy as np
a1 = np.array([[10,20,30],[40,50,60]])
a2 = np.array([1,2,3])
print('a1与a2相加：\n',a1 + a2)
a3 = np.array([[1],[2]])
print('a1与a3相加：\n',a1 + a3)
a4 = np.array(5)
print('a1与a3相加：\n',a1 + a4)